<!DOCTYPE html>
<html>

  <head>
    <meta charset="UTF-8">
    <title></title>
  </head>

  <body>
    <script type="text/javascript">
      //100-200之间的偶数和
      var i = 100;
      var sum = 0;
      while(i <= 200) {
        if(i % 2 == 0) {
          sum += i;
        }
        i++;
      }
      console.log(sum);
      //100以内的质数
      var x = 2;
      while(x <= 100) {
        n = 2;
        var iszhishu = true;
        while(n < x) {
          if(x % n == 0) {
            iszhishu = false;
            break;
          }
          n++;
        }
        if(iszhishu) {
          console.log(x);
        }
        x++;
      }
    </script>
  </body>

</html>